@if(auth()->user()->id === 1)
<div class="form-group">
    <label for="tagUid" class="col-md-3 control-label">所属用户</label>
    <div class="col-md-5">
        <select class="form-control" name="uid" id="tagUid"
                onchange="$('#username').val($(this).find('option:selected').text());">
            @foreach ($userList as $id=>$name)
                <option value="{{ $id }}" @if ($id === $uid) selected="selected" @endif>{{ $name }}</option>
            @endforeach
        </select>
        <input type="hidden" id="username" name="username" value="{{ empty($username) ? $userList[1] : $username}}">
    </div>
</div>
@else
    <input type="hidden" id="username" name="username" value="{{auth()->user()->name}}">
@endif

<div class="form-group">
    <label for="tagWx_num" class="col-md-3 control-label">微信号</label>
    <div class="col-md-5">
		<input type="text" class="form-control" name="wx_num" id="tagWx_num" value="{{ $wx_num }}">
        {{--<textarea class="form-control" rows="3" name="wx_num" id="tagWx_num">{{ $wx_num }}</textarea>--}}
    </div>
</div>
<div class="form-group">
    <label for="tagWx_num" class="col-md-3 control-label">微信昵称</label>
    <div class="col-md-5">
		<input type="text" class="form-control" name="wx_nike" id="tagWx_nike" value="{{ $wx_nike }}">
    </div>
</div>
<div class="form-group">
    <label for="tagGroup" class="col-md-3 control-label">分组</label>
    <div class="col-md-5">
        <select class="form-control" name="group" id="tagGroup">
		<option value="0" @if ($group == 0) selected="selected" @endif>请选择分组</option>
          @foreach($wechatgroup as $v)
            <option value="{{$v['id']}}" @if ($group == $v['id']) selected="selected" @endif>{{$v['name']}}</option>
           @endforeach
        </select>
    </div>
</div>
<div class="form-group">
    <label for="tagPhone" class="col-md-3 control-label">手机号</label>
    <div class="col-md-5">
		<input type="text" class="form-control" name="phone" id="tagPhone" value="{{ $phone }}">
    </div>
</div>
<div class="form-group">
    <label for="tagMax_rand" class="col-md-3 control-label">随机值</label>
    <div class="col-md-5">
		<input type="text" class="form-control" name="max_rand" id="tagMax_rand" value="{{ $max_rand }}">
    </div>
</div>

<div class="form-group">
    <label for="tagOnline_time" class="col-md-3 control-label">客服上线时间</label>
    <div class="col-md-5">
		<input type="time" class="form-control" name="online_time" id="tagOnline_time"  value="{{ $online_time or '09:00' }}">
    </div>
</div>
<div class="form-group">
    <label for="tagOffline_time" class="col-md-3 control-label">客服下线时间</label>
    <div class="col-md-5">
		<input type="time" class="form-control" name="offline_time" id="tagOffline_time" value="{{ $offline_time or '18:00' }}">
    </div>
</div>
<div class="form-group">
    <label for="tagStatus" class="col-md-3 control-label">状态</label>
    <div class="col-md-5">
        <select class="form-control" name="status" id="tagStatus">
          
            <option value="0" @if ($status === 0) selected="selected" @endif>禁用</option>
			<option value="1" @if ($status === 1) selected="selected" @endif>正常</option>
			<option value="2" @if ($status === 2) selected="selected" @endif>暂封</option>
			<option value="3" @if ($status === 3) selected="selected" @endif>永封</option>
            
        </select>
    </div>
</div>
<!--<div class="form-group">
    <label for="tagValues" class="col-md-3 control-label">调用值</label>
    <div class="col-md-5">
		<div id="display_values">
			<h3 style="margin-top:0px;"><span class="label label-success">键 >> 值</span> <i id="" class="fa fa-minus-circle del"></i></h3>
			<h3 style="margin-top:0px;"><span class="label label-success">键 >> 值</span> <i id="" class="fa fa-minus-circle del"></i></h3> 
		</div>
        <button onclick="openAddModal()" type="button" class="btn btn-default btn-md"><i class="fa fa-plus-circle"></i> 新增</button>
		
		<input type="hidden" name="delete_id"/>
    </div>
</div>


 <div class="modal fade" id="modal-addWechatValue" tabIndex="-1">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal">
                        ×
                    </button>
                    <h4 class="modal-title">新增键值</h4>
                </div>
                <div class="modal-body">
                    <form class="form-horizontal" method="POST" onsubmit="return false;" action="/">
                        <input type="hidden" name="_token" value="{{ csrf_token() }}">
                        <input type="hidden" name="update_id" value=""/>
						<div class="form-group">
							<label for="tagAdd_key" class="col-md-2 control-label">键</label>
							<div class="col-md-9">
								<input class="form-control" type="text" name="add_key" value="" placeholder=""/>
							</div>
						</div>
						<div class="form-group">
							<label for="tagAdd_value" class="col-md-2 control-label">值</label>
							<div class="col-md-9">
								<input class="form-control" type="text" name="add_value" value="" placeholder=""/>
							</div>
						</div>
						
                    </form>
                </div>
                <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">
							<i class="fa fa-times-circle"></i>  取消</button>
                        <button type="button" class="btn btn-success" onclick="addWechatValue()">
                            <i class="fa fa-check-circle"></i>  确认
                        </button>
                </div>

            </div>
        </div>
    </div>-->